namespace SPI.AgentServer.Configuration;

public class QwenConfiguration
{
    public string BaseUrl { get; set; } = string.Empty;
    public string Model { get; set; } = string.Empty;
    public int MaxTokens { get; set; } = 2000;
    public double Temperature { get; set; } = 0.7;
    public int Timeout { get; set; } = 30;

    /// <summary>
    /// 是否使用模拟客户端（不调用真实 API）
    /// </summary>
    public bool UseMock { get; set; } = false;

    /// <summary>
    /// 连接模式：direct（直连）、ssh（SSH隧道）、local（本地转发）
    /// </summary>
    public string ConnectionMode { get; set; } = "direct";

    /// <summary>
    /// SSH 隧道配置（当 ConnectionMode = "ssh" 时使用）
    /// </summary>
    public SshTunnelConfiguration? SshTunnel { get; set; }
}

public class SshTunnelConfiguration
{
    public bool Enabled { get; set; } = false;
    public string SshHost { get; set; } = string.Empty;
    public int SshPort { get; set; } = 22;
    public string SshUsername { get; set; } = string.Empty;
    public string SshPassword { get; set; } = string.Empty;
    public int RemotePort { get; set; } = 23333;
    public int LocalPort { get; set; } = 23333;
    public string PlinkPath { get; set; } = "plink.exe";
}
